package com.yeswater.multithread.chapter7;

/**
 * author : yeswater
 * date : 2023/11/6
 *
 *  jvm 的根线程组就是 system,再取父线程组则出现 npe
 */

public class Run_7_2_4 {
    public static void main(String[] args) {
        System.out.println(Thread.currentThread().getThreadGroup().getName());
        System.out.println(Thread.currentThread().getThreadGroup().getParent().getName());
        System.out.println(Thread.currentThread().getThreadGroup().getParent().getParent().getName());
    }
}
